<div class="group frame">
    <div class="frame-left">
        <div class="frame-left-header">
            <div class="input-group input-placeholder">
                <span class="input-group-addon input-group-search">
                    <i class="fa fa-search fa-find"></i>
                </span>
                <input class="form-control frame-left-header-input" type="text" ng-model="keywords" placeholder="搜索"/>
            </div>
        </div>
        <div class="group-gs" resize ng-style="{height:(winHeight-90)+'px'}">
            <div class="group-g" ng-repeat="(code, group) in groups">
                <div class="group-g-header" ng-click="headerClick(code)">
                     <span>
                        <img class="group-icon" ng-src="{{group.open?'/node_static/images/arrow_down.png':'/node_static/images/arrow_right.png'}}"/>
                    </span>
                    <span>
                        {{group.name}}
                    </span>
                </div>
                <div class="group-g-sessions" ng-if="group.open">
                    <span class="frame-left-item-loading" ng-if="!group.groups">加载中...</span>
                    <div ng-class="{'frame-left-item':true,'frame-left-item-select':g.id==selectGroup.id}"
                         ng-click="doSelectGroup(g)"
                         ng-repeat="g in group.groups| filter:{name:keywords}">
                        <span>
                            <img ng-src="{{g.portrait}}"/>
                        </span>
                        <span class="session-label">
                            {{ g.name | limitTo: 10 }}{{g.name.length > 10 ? '...' : ''}}
                        </span>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="frame-right">
        <div class="default-view" ng-hide="selectGroup">
            <img src="/node_static//images/logo.png">
        </div>
        <div class="group-detail" ng-show="selectGroup">
            <div class="group-detail-header">{{selectGroup.name}}</div>
            <!--<div class="group-detail-portrait">-->
                <!--<img ng-src="{{selectGroup.portrait}}"/>-->
            <!--</div>-->
            <!--<div class="group-detail-name">-->
                <!--{{ selectGroup.name | limitTo: 20 }}{{selectGroup.name.length > 20 ? '...' : ''}}-->
            <!--</div>-->
            <div class="group-detail-users clearfix">
                <div class="group-detail-user" ng-repeat="user in users" ng-click="goUserSession(user.id)">
                    <div class="group-detail-user-img">
                        <img ng-src="{{user.portrait}}"/>
                    </div>
                    <div class="group-detail-user-name" tooltip="{{user.name}}">
                        {{ user.name | limitTo: 10 }}{{user.name.length > 10 ? '...' : ''}}
                    </div>
                </div>
                <div class="group-detail-user" ng-if="selectGroup.type!=5">
                    <div class="group-detail-user-add">
                        <div class="group-detail-user-fa-bg">
                            <span class="group-detail-user-fa"><i class="fa fa-plus" ng-click="openGroup(users)"></i></span>
                        </div>
                    </div>
                    <div class="group-detail-user-add-name">
                        添加
                    </div>
                </div>
            </div>
            <div class="group-detail-btn">
                <button class="btn btn-warning" ng-disabled="isGoing" ng-click="goSession()">{{isGoing?'发起中':'发起会话'}}</button>
            </div>
        </div>
    </div>
</div>
